﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Reflection;
using System.Xml.Serialization;

using Idlesoft.Utils;
using System.Xml;
namespace Idlesoft.Cli
{

    //[AttributeUsage(AttributeTargets.Property, AllowMultiple = false)]
    //public abstract class CliAttribute : XmlAttributeAttribute
    //{
    //    public CliAttribute(string[] flags) : base()
    //    {
    //        Flags = flags;
    //        FlagTypes = FlagTypes.Undef;
    //    }
    //    #region props
    //    public FlagTypes FlagTypes { get; set; }
    //    public string Name { get; set; }
    //    public string Description { get; set; }
    //    public string[] Flags { get; set; }
    //    public object[] Values { get; internal set; }
    //    public MemberInfo MemberInfo { get; set; }
    //    #endregion props

    //    #region methods
    //    public override string ToString()
    //    {
    //        return string.Format("Name={0} Types={1} Flags={2} Values={3}", Name, FlagTypes, Flags.Flatten("|"), Values.Flatten("|"));
    //    }
    //    public override bool Equals(object obj)
    //    {
    //        bool equals = false;
    //        CliAttribute rhs = obj as CliAttribute;
    //        if (rhs != null)
    //        {
    //            if (MemberInfo != null && rhs.MemberInfo != null)
    //                equals = MemberInfo.Equals(rhs.MemberInfo);
    //        }
    //        return equals;
    //    }
    //    public override int GetHashCode()
    //    {
    //        return base.GetHashCode();
    //    }
    //    #endregion methods
    //}

    //[AttributeUsage(AttributeTargets.Property, AllowMultiple = false)]
    //public class CliOption : CliAttribute
    //{
    //    public CliOption(params string[] flags) : base(flags) { }
    //    public object Default { get; set; }
    //}

    //[AttributeUsage(AttributeTargets.Property, AllowMultiple = false)]
    //public class CliRequired : CliAttribute
    //{
    //    public CliRequired(params string[] flags) : base(flags) { }
    //}

    //internal class CliBuiltIn : CliAttribute
    //{
    //    public CliBuiltIn(params string[] flags) : base(flags) { }
    //}
}
